package com.mixsmart.bean;

import com.mixsmart.enums.YesNoType;

import java.util.Date;
import java.util.Set;

/**
 * @author 乌草坡 2024-05-07
 * @since 6.0.4
 */
public class SourceTestBean {

    private String id;

    private String corpId;

    private String name;

    private String uri;

    private Date createTime;

    private String parentId = "0";

    private String authValue;

    private String authText;

    private Integer state = YesNoType.YES.getIndex();

    private String type;

    /**
     * 资源来源ID；
     * 如：
     * 如果来源是报表时，该字段值为报表ID，
     * 如果来源是表单时，该值为表单ID，
     * 如果资源是手动添加的URL，则该字段值为空
     */
    private String sourceId;

    /**
     * 是否需要授权;默认为需要授权
     */
    private Boolean isAuthorize = YesNoType.YES.getValue();

    private Integer sortOrder = 0;

    //非持久化属性，该资源的权限值
    private Set<ResourceAuthValue> authValues;

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getCorpId() {
        return corpId;
    }

    public void setCorpId(String corpId) {
        this.corpId = corpId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getUri() {
        return uri;
    }

    public void setUri(String uri) {
        this.uri = uri;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    public String getParentId() {
        return parentId;
    }

    public void setParentId(String parentId) {
        this.parentId = parentId;
    }

    public String getAuthValue() {
        return authValue;
    }

    public void setAuthValue(String authValue) {
        this.authValue = authValue;
    }

    public String getAuthText() {
        return authText;
    }

    public void setAuthText(String authText) {
        this.authText = authText;
    }

    public Integer getState() {
        return state;
    }

    public void setState(Integer state) {
        this.state = state;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getSourceId() {
        return sourceId;
    }

    public void setSourceId(String sourceId) {
        this.sourceId = sourceId;
    }

    public Boolean getAuthorize() {
        return isAuthorize;
    }

    public void setAuthorize(Boolean authorize) {
        isAuthorize = authorize;
    }

    public Integer getSortOrder() {
        return sortOrder;
    }

    public void setSortOrder(Integer sortOrder) {
        this.sortOrder = sortOrder;
    }

    public Set<ResourceAuthValue> getAuthValues() {
        return authValues;
    }

    public void setAuthValues(Set<ResourceAuthValue> authValues) {
        this.authValues = authValues;
    }
}
